package com.dpiinc.TechPage.pen.dialog;

import android.content.Context;
import android.os.Bundle;

import com.dpiinc.TechPage.R;

import org.jetbrains.annotations.Nullable;

/**
 * Created by hu489_000 on 2018-07-23.
 */

public class ProgressDialog extends BaseFloatDialog {

    public interface OnClickEditListener {
        public void onClickEdit(String text);
    }

    private static ProgressDialog mOneButtonDialog;

    private Context mContext;

    public ProgressDialog(@Nullable Context context) {
        super(context);
    }

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        setContentView(R.layout.toast_submitting);
    }

    public static void ShowDialog(@Nullable Context context) {
        mOneButtonDialog = new ProgressDialog(context);
        mOneButtonDialog.show();

    }

    public static void dismissDialog() {

        if (mOneButtonDialog != null && mOneButtonDialog.isShowing()) {
            mOneButtonDialog.dismiss();
        }

    }
}
